package com.ruoyi.peoplegroup.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.peoplegroup.mapper.ResearcherinfoHistoryMapper;
import com.ruoyi.peoplegroup.domain.ResearcherinfoHistory;
import com.ruoyi.peoplegroup.service.IResearcherinfoHistoryService;

/**
 * 科研人员信息历史跟踪Service业务层处理
 *
 * @author lh
 * @date 2025-01-16
 */
@Service
public class ResearcherinfoHistoryServiceImpl implements IResearcherinfoHistoryService
{
    @Autowired
    private ResearcherinfoHistoryMapper researcherinfoHistoryMapper;

    /**
     * 查询科研人员信息历史跟踪
     *
     * @param researcherinfoHistoryId 科研人员信息历史跟踪主键
     * @return 科研人员信息历史跟踪
     */
    @Override
    public ResearcherinfoHistory selectResearcherinfoHistoryByResearcherinfoHistoryId(Long researcherinfoHistoryId)
    {
        return researcherinfoHistoryMapper.selectResearcherinfoHistoryByResearcherinfoHistoryId(researcherinfoHistoryId);
    }

    /**
     * 查询科研人员信息历史跟踪列表
     *
     * @param researcherinfoHistory 科研人员信息历史跟踪
     * @return 科研人员信息历史跟踪
     */
    @Override
    public List<ResearcherinfoHistory> selectResearcherinfoHistoryList(ResearcherinfoHistory researcherinfoHistory)
    {
        return researcherinfoHistoryMapper.selectResearcherinfoHistoryList(researcherinfoHistory);
    }

    /**
     * 新增科研人员信息历史跟踪
     *
     * @param researcherinfoHistory 科研人员信息历史跟踪
     * @return 结果
     */
    @Override
    public int insertResearcherinfoHistory(ResearcherinfoHistory researcherinfoHistory)
    {
        return researcherinfoHistoryMapper.insertResearcherinfoHistory(researcherinfoHistory);
    }

    /**
     * 修改科研人员信息历史跟踪
     *
     * @param researcherinfoHistory 科研人员信息历史跟踪
     * @return 结果
     */
    @Override
    public int updateResearcherinfoHistory(ResearcherinfoHistory researcherinfoHistory)
    {
        return researcherinfoHistoryMapper.updateResearcherinfoHistory(researcherinfoHistory);
    }

    /**
     * 批量删除科研人员信息历史跟踪
     *
     * @param researcherinfoHistoryIds 需要删除的科研人员信息历史跟踪主键
     * @return 结果
     */
    @Override
    public int deleteResearcherinfoHistoryByResearcherinfoHistoryIds(Long[] researcherinfoHistoryIds)
    {
        return researcherinfoHistoryMapper.deleteResearcherinfoHistoryByResearcherinfoHistoryIds(researcherinfoHistoryIds);
    }

    /**
     * 删除科研人员信息历史跟踪信息
     *
     * @param researcherinfoHistoryId 科研人员信息历史跟踪主键
     * @return 结果
     */
    @Override
    public int deleteResearcherinfoHistoryByResearcherinfoHistoryId(Long researcherinfoHistoryId)
    {
        return researcherinfoHistoryMapper.deleteResearcherinfoHistoryByResearcherinfoHistoryId(researcherinfoHistoryId);
    }


    @Override
    public List<ResearcherinfoHistory> selectAllResearcherinfoHistory() {
        return researcherinfoHistoryMapper.selectAllResearcherinfoHistory();
    }

    @Override
    public List<ResearcherinfoHistory> selectResearcherinfoHistoryByresearcherId(Long researcherId) {
        return researcherinfoHistoryMapper.selectAllResearcherinfoHistoryByresearcherId(researcherId);
    }
}
